package com.yonxao.demo.crud.annotation.serializer;

import com.fasterxml.jackson.annotation.JacksonAnnotationsInside;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * 序列化时将 Integer 型数字除以 100 转为浮点型
 *
 * @author xiaosaguo
 * @date 2020/09/08 20:21
 */
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD, ElementType.METHOD})
@JacksonAnnotationsInside
@JsonSerialize(using = IntegerDivideHundredJsonSerializer.class)
public @interface IntegerDivideHundred {
}
